package ltd.cheers.mall.dao;

import ltd.cheers.mall.entity.CheersMallShoppingCartItem;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface CheersMallShoppingCartItemMapper {
    int deleteByPrimaryKey(Long cartItemId);

    int insert(CheersMallShoppingCartItem record);

    int insertSelective(CheersMallShoppingCartItem record);

    CheersMallShoppingCartItem selectByPrimaryKey(Long cartItemId);

    CheersMallShoppingCartItem selectByUserIdAndGoodsId(@Param("cheersMallUserId") Long cheersMallUserId, @Param("goodsId") Long goodsId);

    List<CheersMallShoppingCartItem> selectByUserId(@Param("cheersMallUserId") Long cheersMallUserId, @Param("number") int number);

    int selectCountByUserId(Long cheersMallUserId);

    int updateByPrimaryKeySelective(CheersMallShoppingCartItem record);

    int updateByPrimaryKey(CheersMallShoppingCartItem record);

    int deleteBatch(List<Long> ids);
}